﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using AsPlugInManager;
using AsLib;

namespace NNLInterface
{
    public partial class common 
    {
        //定义记录集
        public struct dbRecord
        {
            public DataTable ADODataRst;
            public int RecordNumber;
        }

        public struct View
        {
            public DataView ADOViewRst;
            public int RecordNumber;
        }

        //定义订单的要保留的字段
        public struct orderFiled
        {
            public string orderCode;
            public double orderPriority;
            public double orderProductionFactor;
            public int orderDisabled;
            public double orderNumSpec3;
            public string Comment;
        }

        //数据表格的显示模式
        public enum enumGridStyle
        {
            InputStyle = 0,
            ViewStyle = 1,
            ViewReportStyle = 2
        };

        //定义存储过程的
        public enum Choose
        {
            HasAOutput = 0,
            OnlyExecSp,
            RetOneRecord
        };

        //定义数据源类型
        public enum DataSourceType
        {
            TXT = 0,
            SQLSERVER = 1,
            ORACLE = 2
        };

        //定义数据的状态
        public enum DataModifyMode
        {
            view = 0,
            add = 1,
            edit = 2
        };

        /*  定义语系类型 */
        public enum Language
        {
            CHINESE = 0,
            ENGLISH = 1,
            Janpanese = 2
        };

        //定义基form的工具栏的按钮的可视性
        public enum ToolVisible
        {
            BasicEntry = 0,
            BasicDetailEntry = 1,
            MasterData = 2,
            QueryData=3,
            ImportData=4,
            Information=5,
            Business=6,
            BasicDetailEntryC = 7
        };

        //定义导入的Excel文件类型
        public enum ExccelFileType
        {
            Material,
            OrderData
        };

        //定义皮肤的风格
        public enum FormSkin
        {
            DevExpressStyle = 0,
            Caramel = 1,
            MoneyTwins = 2,
            Lilian = 3,
            DevExpressDarkStyle = 4,
            iMaginary = 5,
            Black = 6,
            Blue = 7,
            Office2007Blue = 8,
            Office2007Black = 9,
            Office2007Silver = 10,
            Office2007Green = 11,
            Office2007Pink = 12,
            Office2010Blue = 13,
            Office2010Black = 14,
            Office2010Silver = 15,
            Coffee = 16,
            LiquidSky = 17,
            LondonLiquidSky = 18,
            GlassOceans = 19,
            Stardust = 20,
            Xmas2008Blue = 21,
            Valentine = 22,
            McSkin = 23,
            Summer2008 = 24,
            Pumpkin = 25,
            DarkSide = 26,
            Springtime = 27,
            Darkroom = 28,
            Foggy = 29,
            HighContrast = 30,
            Seven = 31,
            SevenClassic = 32,
            Sharp = 33,
            SharpPlus = 34,
            TheAsphaltWorld = 35,
            Blueprint = 36,
            Whiteprint = 37


        };



        //定义数据导出方式
        public enum ExportType
        {
            Export = 0,
            Import = 1
        };

        //定义BOM导入到Asprova的数据类型
        public enum enumBomImportType
        {
            Y = 1,                   //差分
            R = 2,                  //替换
            FR = 3,               //强制替换
            RI = 4,              //替换品目单位
            FRI = 5              //强制替换品目单位
        };

        //定义订单导出时的类型选择
        public enum enumOrderExportType
        {
            //X=1,            //0,X,未指定
            //T=2,           //50,T,开始生产
            //B=3         //100,B,结束
            P = 1,
            F = 2,
            R = 3,
            E = 4,
            C = 5,
            A = 6
        };

        //定义订单导出时的类型选择
        public enum enumOrderType
        {
            SC = 1,
            S4230 = 2
        };

        //定义工作导出时的类型选择
        public enum enumPlanExportType
        {
            O = 1,      //0,,未指定    
            N = 2,      //1,N,未计划    
            A = 3,      //2,A,计划完毕
            I = 4,      //3,I,指示完毕
            D = 5,      //;4,D,确定
            T = 6,      //5,T,开始生产
            B = 7       //6,B,结束
        };

        
         //系统参数
        public static NNLInterface.sysrun sysParameter;
        public static accessdb _its_accessdb;
        

        public static string _userid = "";                                                      //登录用户编号
        public static string _password = "";                                                    //登录用户密码 
        public static string _username = "";                                                    //登录用户名称 
        public static string _DeptNo = "";                                                    //登录部门编号 
        public static string _DeptName = "";                                                    //登录部门名称 
        
        public static rwconfig RWLang;                                                          //系统参数提取变量


        public static ASPArgList agrs;                                     //Asprova项目变量                                                                             //Asprova全局变量
        public static AsLib.IASBProject pro;


        //全局连接字串,从INI文件中读取
        public static string strConnect;   
  
        //定义第三方ERP的连接字串
        public static string strERPConnect;
    }
}
